<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
    <div>{{ myadd(3,2) }}</div>
    {# 这里是jinjia2的注释 #}
    <div>{{session.get('username')}}, 欢迎你登录慕慕手记</div>
    <div>文章的标题是：{{article.title}}</div>
    <div>文章的阅读量是：{{article.count}}</div>

    {% if article.count % 2 == 0 %}
    <span>你的阅读量可以被2整除，是一个偶数</span>
    {% else %}
    <span>你的阅读量不可以被2整除，是一个奇数</span>
    {% endif %}

    {% set loopCount = article.count / 100 %}
    {% set intLoopCount = loopCount | int %}
    {#    {% set intLoopCount = int(loopCount) %}  #}

    {# jinjia2的for循环 #}
    {% for i in range(intLoopCount) %}
        <div>当前的循环次数是：{{ i + 1 }}</div>
    {% endfor %}

    <div>{{ article.content | safe }}</div>
    <div>{{ 'hello world' | upper }}</div>
    <div>{{ 'hello world' | lower }}</div>
    <div>{{ 'hello world' | title }}</div>
    <div>{{ 1 | add }}</div>

</body>
</html>